package com.github.catvod.spider.merge;

import com.github.catvod.spider.merge.HZ;

/* loaded from: classes.dex */
public class IG extends ND {
    public IG(String str) {
        this.q = str;
    }

    static boolean SS(StringBuilder sb) {
        return sb.length() != 0 && sb.charAt(sb.length() - 1) == ' ';
    }

    public boolean HU() {
        return ZG.oC(qG());
    }

    public String M() {
        return qG();
    }

    /* JADX WARN: Code restructure failed: missing block: B:10:0x0022, code lost:
    
        if (HU() == false) goto L18;
     */
    /* JADX WARN: Code restructure failed: missing block: B:11:0x003a, code lost:
    
        j5(r10, r11, r12);
     */
    /* JADX WARN: Code restructure failed: missing block: B:17:0x0038, code lost:
    
        if (HU() == false) goto L18;
     */
    @Override // com.github.catvod.spider.merge.fa
    /*
        Code decompiled incorrectly, please refer to instructions dump.
        To view partially-correct add '--show-bad-code' argument
    */
    void Og(java.lang.Appendable r10, int r11, com.github.catvod.spider.merge.HZ.Tw r12) {
        /*
            r9 = this;
            boolean r0 = r12.u()
            if (r0 == 0) goto L3d
            int r1 = r9.hr()
            if (r1 != 0) goto L24
            com.github.catvod.spider.merge.fa r1 = r9.V0
            boolean r2 = r1 instanceof com.github.catvod.spider.merge.Lm
            if (r2 == 0) goto L24
            com.github.catvod.spider.merge.Lm r1 = (com.github.catvod.spider.merge.Lm) r1
            com.github.catvod.spider.merge.iP r1 = r1.XA()
            boolean r1 = r1.V0()
            if (r1 == 0) goto L24
            boolean r1 = r9.HU()
            if (r1 == 0) goto L3a
        L24:
            boolean r1 = r12.BQ()
            if (r1 == 0) goto L3d
            java.util.List r1 = r9.v()
            int r1 = r1.size()
            if (r1 <= 0) goto L3d
            boolean r1 = r9.HU()
            if (r1 != 0) goto L3d
        L3a:
            r9.j5(r10, r11, r12)
        L3d:
            r11 = 1
            r1 = 0
            if (r0 == 0) goto L4b
            com.github.catvod.spider.merge.fa r2 = r9.V0
            boolean r2 = com.github.catvod.spider.merge.Lm.vm(r2)
            if (r2 != 0) goto L4b
            r7 = 1
            goto L4c
        L4b:
            r7 = 0
        L4c:
            if (r0 == 0) goto L56
            com.github.catvod.spider.merge.fa r0 = r9.V0
            boolean r0 = r0 instanceof com.github.catvod.spider.merge.HZ
            if (r0 == 0) goto L56
            r8 = 1
            goto L57
        L56:
            r8 = 0
        L57:
            java.lang.String r4 = r9.qG()
            r6 = 0
            r3 = r10
            r5 = r12
            com.github.catvod.spider.merge.XR.I(r3, r4, r5, r6, r7, r8)
            return
        */
        throw new UnsupportedOperationException("Method not decompiled: com.github.catvod.spider.merge.IG.Og(java.lang.Appendable, int, com.github.catvod.spider.merge.HZ$Tw):void");
    }

    @Override // com.github.catvod.spider.merge.fa
    public String PU() {
        return "#text";
    }

    @Override // com.github.catvod.spider.merge.fa
    void R(Appendable appendable, int i, HZ.Tw tw) {
    }

    @Override // com.github.catvod.spider.merge.fa
    /* renamed from: ap, reason: merged with bridge method [inline-methods] */
    public IG oq() {
        return (IG) super.oq();
    }

    @Override // com.github.catvod.spider.merge.ND, com.github.catvod.spider.merge.fa
    public /* bridge */ /* synthetic */ String h(String str) {
        return super.h(str);
    }

    @Override // com.github.catvod.spider.merge.ND, com.github.catvod.spider.merge.fa
    public /* bridge */ /* synthetic */ String j(String str) {
        return super.j(str);
    }

    @Override // com.github.catvod.spider.merge.ND, com.github.catvod.spider.merge.fa
    public /* bridge */ /* synthetic */ fa n() {
        return super.n();
    }

    @Override // com.github.catvod.spider.merge.ND, com.github.catvod.spider.merge.fa
    public /* bridge */ /* synthetic */ String oC() {
        return super.oC();
    }

    @Override // com.github.catvod.spider.merge.fa
    public String toString() {
        return w4();
    }

    @Override // com.github.catvod.spider.merge.ND, com.github.catvod.spider.merge.fa
    public /* bridge */ /* synthetic */ int u() {
        return super.u();
    }
}
